<TagAttribute("gbxmodel","mod2","????","????",5,232)>
Public Class GBXMODEL_TAG
Inherits HaloTag
Public Const Extension as String = "gbxmodel"
Public Const FourCC as String = "mod2"
Public Const ParentFourCC as String = "????"
Public Const GrandParentFourCC as String = "????"
Public Const [Version] as Short = 5
Public Const HeaderLength as Integer = 232

''' <summary>
''' 
''' </summary>
<TagField("flags*", 1, 20)>
Public flags as Integer

''' <summary>
''' 
''' </summary>
<TagField("node list checksum", 1, 4)>
Public node_list_checksum as Integer

''' <summary>
''' 
''' </summary>
<TagField("super-high detail cutoff:pixels", 1, 0)>
Public super as Single

''' <summary>
''' 
''' </summary>
<TagField("high detail cutoff:pixels", 1, 0)>
Public high_detail_cutoff as Single

''' <summary>
''' 
''' </summary>
<TagField("medium detail cutoff:pixels", 1, 0)>
Public medium_detail_cutoff as Single

''' <summary>
''' 
''' </summary>
<TagField("low detail cutoff:pixels", 1, 0)>
Public low_detail_cutoff as Single

''' <summary>
''' 
''' </summary>
<TagField("super-low cutoff:pixels", 1, 0)>
Public super_1 as Single

''' <summary>
''' 
''' </summary>
<TagField("super-high detail node count", 1, 23)>
Public super_2 as Short

''' <summary>
''' 
''' </summary>
<TagField("high detail node count", 1, 23)>
Public high_detail_node_count as Short

''' <summary>
''' 
''' </summary>
<TagField("medium detail node count", 1, 23)>
Public medium_detail_node_count as Short

''' <summary>
''' 
''' </summary>
<TagField("low detail node count", 1, 23)>
Public low_detail_node_count as Short

''' <summary>
''' 
''' </summary>
<TagField("super-low detail node count", 1, 23)>
Public super_3 as Short

''' <summary>
''' 
''' </summary>
<TagField("", 2, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("", 8, -1)>
Public padding_1 as Byte()

''' <summary>
''' 
''' </summary>
<TagField("base map u-scale", 1, 0)>
Public base_map_u as Single

''' <summary>
''' 
''' </summary>
<TagField("base map v-scale", 1, 0)>
Public base_map_v as Single

''' <summary>
''' 
''' </summary>
<TagField("", 116, -1)>
Public padding_2 as Byte()

''' <summary>
''' model_markers_block
''' </summary>
<TagField("markers", 64, 11)>
Public markers as List(Of MARKERS_BLOCK)

''' <summary>
''' model_node_block
''' </summary>
<TagField("nodes", 156, 11)>
Public nodes as List(Of NODES_BLOCK)

''' <summary>
''' gbxmodel_region_block
''' </summary>
<TagField("regions", 76, 11)>
Public regions as List(Of REGIONS_BLOCK)

''' <summary>
''' gbxmodel_geometry_block
''' </summary>
<TagField("geometries", 48, 11)>
Public geometries as List(Of GEOMETRIES_BLOCK)

''' <summary>
''' model_shader_reference_block
''' </summary>
<TagField("shaders", 32, 11)>
Public shaders as List(Of SHADERS_BLOCK)
Public Class MARKERS_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("name^", 32, 8)>
Public name as String

''' <summary>
''' 
''' </summary>
<TagField("magic identifier", 1, 23)>
Public magic_identifier as Short

''' <summary>
''' 
''' </summary>
<TagField("", 2, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("", 16, -1)>
Public padding_1 as Byte()

''' <summary>
''' model_marker_instance_block
''' </summary>
<TagField("instances", 32, 11)>
Public instances as List(Of INSTANCES_BLOCK)
Public Class INSTANCES_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("region index", 1, 9)>
Public region_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("permutation index", 1, 9)>
Public permutation_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("node index", 1, 9)>
Public node_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("", 1, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("translation", 3, 2)>
Public translation as Single()

''' <summary>
''' 
''' </summary>
<TagField("rotation", 4, 3)>
Public rotation as Single()

End Class

End Class
Public Class NODES_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("name^", 32, 8)>
Public name as String

''' <summary>
''' 
''' </summary>
<TagField("next sibling node index", 1, 23)>
Public next_sibling_node_index as Short

''' <summary>
''' 
''' </summary>
<TagField("first child node index", 1, 23)>
Public first_child_node_index as Short

''' <summary>
''' 
''' </summary>
<TagField("parent node index", 1, 23)>
Public parent_node_index as Short

''' <summary>
''' 
''' </summary>
<TagField("", 2, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("default translation", 3, 2)>
Public default_translation as Single()

''' <summary>
''' 
''' </summary>
<TagField("default rotation", 4, 3)>
Public default_rotation as Single()

''' <summary>
''' 
''' </summary>
<TagField("node distance from parent", 1, 0)>
Public node_distance_from_parent as Single

''' <summary>
''' 
''' </summary>
<TagField("", 32, -1)>
Public padding_1 as Byte()

''' <summary>
''' 
''' </summary>
<TagField("", 52, -1)>
Public padding_2 as Byte()

End Class
Public Class REGIONS_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("name^", 32, 8)>
Public name as String

''' <summary>
''' 
''' </summary>
<TagField("", 32, -1)>
Public padding as Byte()

''' <summary>
''' gbxmodel_region_permutation_block
''' </summary>
<TagField("permutations", 88, 11)>
Public permutations as List(Of PERMUTATIONS_BLOCK)
Public Class PERMUTATIONS_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("name^", 32, 8)>
Public name as String

''' <summary>
''' 
''' </summary>
<TagField("flags*", 1, 20)>
Public flags as Integer

''' <summary>
''' 
''' </summary>
<TagField("", 28, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("super low", 1, 23)>
Public super_low as Short

''' <summary>
''' 
''' </summary>
<TagField("low", 1, 23)>
Public low as Short

''' <summary>
''' 
''' </summary>
<TagField("medium", 1, 23)>
Public medium as Short

''' <summary>
''' 
''' </summary>
<TagField("high", 1, 23)>
Public high as Short

''' <summary>
''' 
''' </summary>
<TagField("super high", 1, 23)>
Public super_high as Short

''' <summary>
''' 
''' </summary>
<TagField("", 2, -1)>
Public padding_1 as Byte()

''' <summary>
''' model_region_permutation_marker_block
''' </summary>
<TagField("markers", 80, 11)>
Public markers as List(Of MARKERS_BLOCK)
Public Class MARKERS_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("name^", 32, 8)>
Public name as String

''' <summary>
''' 
''' </summary>
<TagField("node index", 1, 23)>
Public node_index as Short

''' <summary>
''' 
''' </summary>
<TagField("", 2, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("rotation", 4, 3)>
Public rotation as Single()

''' <summary>
''' 
''' </summary>
<TagField("translation", 3, 2)>
Public translation as Single()

''' <summary>
''' 
''' </summary>
<TagField("", 16, -1)>
Public padding_1 as Byte()

End Class

End Class

End Class
Public Class GEOMETRIES_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("flags*", 1, 20)>
Public flags as Integer

''' <summary>
''' 
''' </summary>
<TagField("", 32, -1)>
Public padding as Byte()

''' <summary>
''' gbxmodel_geometry_part_block
''' </summary>
<TagField("parts", 132, 11)>
Public parts as List(Of PARTS_BLOCK)
Public Class PARTS_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("flags*", 1, 20)>
Public flags as Integer

''' <summary>
''' 
''' </summary>
<TagField("shader index", 1, 23)>
Public shader_index as Short

''' <summary>
''' 
''' </summary>
<TagField("prev filthy part index", 1, 9)>
Public prev_filthy_part_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("next filthy part index", 1, 9)>
Public next_filthy_part_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("centroid primary node", 1, 23)>
Public centroid_primary_node as Short

''' <summary>
''' 
''' </summary>
<TagField("centroid secondary node", 1, 23)>
Public centroid_secondary_node as Short

''' <summary>
''' 
''' </summary>
<TagField("centroid primary weight", 1, 0)>
Public centroid_primary_weight as Single

''' <summary>
''' 
''' </summary>
<TagField("centroid secondary weight", 1, 0)>
Public centroid_secondary_weight as Single

''' <summary>
''' 
''' </summary>
<TagField("centroid", 3, 2)>
Public centroid as Single()

''' <summary>
''' model_vertex_uncompressed_block
''' </summary>
<TagField("uncompressed vertices", 68, 11)>
Public uncompressed_vertices as List(Of UNCOMPRESSED_VERTICES_BLOCK)

''' <summary>
''' model_vertex_compressed_block
''' </summary>
<TagField("compressed vertices", 32, 11)>
Public compressed_vertices as List(Of COMPRESSED_VERTICES_BLOCK)

''' <summary>
''' model_triangle_block
''' </summary>
<TagField("triangles", 6, 11)>
Public triangles as List(Of TRIANGLES_BLOCK)

''' <summary>
''' 
''' </summary>
<TagField("", 4, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("", 4, 13)>
Public unknown as Integer()

''' <summary>
''' 
''' </summary>
<TagField("", 4, 14)>
Public unknown_1 as Integer()

''' <summary>
''' 
''' </summary>
<TagField("shorten me", 28, -1)>
Public shorten_me as Byte()
Public Class UNCOMPRESSED_VERTICES_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("position", 3, 2)>
Public position as Single()

''' <summary>
''' 
''' </summary>
<TagField("normal", 3, 2)>
Public normal as Single()

''' <summary>
''' 
''' </summary>
<TagField("binormal", 3, 2)>
Public binormal as Single()

''' <summary>
''' 
''' </summary>
<TagField("tangent", 3, 2)>
Public tangent as Single()

''' <summary>
''' 
''' </summary>
<TagField("texture coords", 2, 1)>
Public texture_coords as Single()

''' <summary>
''' 
''' </summary>
<TagField("node0 index", 1, 23)>
Public node0_index as Short

''' <summary>
''' 
''' </summary>
<TagField("node1 index", 1, 23)>
Public node1_index as Short

''' <summary>
''' 
''' </summary>
<TagField("node0 weight", 1, 0)>
Public node0_weight as Single

''' <summary>
''' 
''' </summary>
<TagField("node1 weight", 1, 0)>
Public node1_weight as Single

End Class
Public Class COMPRESSED_VERTICES_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("position", 3, 2)>
Public position as Single()

''' <summary>
''' 
''' </summary>
<TagField("normal[11.11.10-bit]", 1, 4)>
Public normal as Integer

''' <summary>
''' 
''' </summary>
<TagField("binormal[11.11.10-bit]", 1, 4)>
Public binormal as Integer

''' <summary>
''' 
''' </summary>
<TagField("tangent[11.11.10-bit]", 1, 4)>
Public tangent as Integer

''' <summary>
''' 
''' </summary>
<TagField("texture coordinate u[16-bit]", 1, 23)>
Public texture_coordinate_u as Short

''' <summary>
''' 
''' </summary>
<TagField("texture coordinate v[16-bit]", 1, 23)>
Public texture_coordinate_v as Short

''' <summary>
''' 
''' </summary>
<TagField("node0 index(x3)", 1, 9)>
Public node0_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("node1 index(x3)", 1, 9)>
Public node1_index as Byte

''' <summary>
''' 
''' </summary>
<TagField("node0 weight[16-bit]", 1, 23)>
Public node0_weight as Short

End Class
Public Class TRIANGLES_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("vertex0 index", 1, 23)>
Public vertex0_index as Short

''' <summary>
''' 
''' </summary>
<TagField("vertex1 index", 1, 23)>
Public vertex1_index as Short

''' <summary>
''' 
''' </summary>
<TagField("vertex2 index", 1, 23)>
Public vertex2_index as Short

End Class

End Class

End Class
Public Class SHADERS_BLOCK

''' <summary>
''' 
''' </summary>
<TagField("shader^", 16, 10)>
Public shader as New TAG_REFERENCE

''' <summary>
''' 
''' </summary>
<TagField("permutation", 1, 23)>
Public permutation as Short

''' <summary>
''' 
''' </summary>
<TagField("", 2, -1)>
Public padding as Byte()

''' <summary>
''' 
''' </summary>
<TagField("", 12, -1)>
Public padding_1 as Byte()

End Class

End Class
